﻿using System;
using System.Windows.Forms;

namespace SplitScreenDemo
{
    public partial class frmChild : Form
    {
        public frmChild()
        {
            InitializeComponent();
        }

        private void frmChild_Load(object sender, EventArgs e)
        {
            
            InitDelegate();
        }

        private void InitDelegate()
        {
            frmMain frm = (frmMain)this.Owner;
            frm.RefreshParent = null;
            //注册父窗体委托
            frm.RefreshParent += txt => {
                lbmess.Text = txt;
            };
        }
    }
}
